package com.yq.cns.adapter.newsitem

import cn.jzvd.JzvdStd
import com.chad.library.adapter.base.provider.BaseItemProvider
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.yq.cns.R
import com.yq.cns.entity.ListItemType
import com.yq.cns.entity.NewsListEntity

class LargeVideoNewsItemProvider : BaseItemProvider<NewsListEntity>() {
    override val itemViewType: Int
            get() = ListItemType.TYPE_LARGE_VIDEO
    override val layoutId: Int
        get() = R.layout.news_item_large_video

    override fun convert(helper: BaseViewHolder, item: NewsListEntity) {
        val videoUrl = item.video
        val jzVide = helper.getView<JzvdStd>(R.id.video_player)
        jzVide.setUp(videoUrl,"测试标题")
    }
}